1. Field of the Invention
This invention relates to image processing technologies and, more particularly, to an improved image processing system and method employing user-configurable virtual objects representing lenses and image processing operations.
2. Description of the Related Art
Related U.S. Pat. No. 5,425,137 (the '137 patent) describes an object-based image processing system and method wherein operations to be performed on the background image are defined in terms of a plurality of virtual lens objects, or "lenses". Each lens object represents one or more operations that are defined by user-specified lens attributes. One such attribute specifies the region of operation of the lens object. Other lens attributes specify the type and magnitude of operations to be performed on the underlying image within the defined region of the lens object. These operations may simulate actual physical lens behavior (such as enlarging or distorting the image) or they may be more abstract (such as making a color image black-and-white).
The user may also specify operations that are not part of lens objects. Such operations are still movable and modifiable in a similar manner as lens objects. This type of representation may be preferable for some types of operations, such as paint strokes. In the present application, the term "objects" refers to both lens objects and independent operations.
The user may specify any number of operations for a given lens object. Furthermore, the user may specify any number of objects (lens objects and/or independent operations) to operate on a given image. The regions of operation may or may not overlap one another, according to the user's preference. Objects are applied to the image in a user-specified order, so that overlapping objects form a virtual stack. When regions overlap one another, the transformed image that results from application of the first (or lowest level) object becomes input for subsequent (higher level) objects. Thus, as in a stack of real, physical lenses, lens operations and independent operations are cumulative.
Each image processing operation is recorded as an object so that it may be individually selected, modified, transformed or deleted without altering the original image. This facilitates user experimentation with various image processing options and combinations.
When objects overlap one another, the results of the first object's operations are in turn used as a source image for the second, overlapping, object's operations. A chain of operations represented by successively overlapping objects is thus formed. Any change in one of the operations in the chain may require re-application of one or more of the overlapping operations in the chain. One advantage of the invention described in the '137 patent is that when an operation is modified, the user is not required to keep track of other operations that will be affected by the modification or to manually redo work that is affected by the modification. Rather, the system performs automatic updates of the affected regions, including redoing any operations of overlapping objects as required.
When a change is made to an operation for a particular region of the image, some or all of the other operations for that region may have to be re-applied using new source image data. In order to facilitate automatic re-application, the invention described in the '137 patent maintains an object-oriented database of user operations containing information describing the sequence of operations and the area of application for each operation. Thus, referring now to FIG. 1b, there is shown a conceptual representation of the operation of the system of the '137 patent. Operations 102-110, represented by the letters A through I, are shown operating on particular regions of background image 101. The system attempts to optimize the speed of updating when operations change by selectively re-applying operations only to areas affected by the change. Thus, in the example shown in FIG. 1b, if the user modifies operation D 105, rather than re-applying the entire sequence of operations A through I to update the image, the system determines the minimum area of the image requiring update, and only reapplies operations affecting that area. In the example of FIG. 1b, only operations A, C, D, G, and H fall into the area affected by operation D. Therefore, after the change in operation D, only operations A, C, D, G, and H need to be re-applied. By avoiding unnecessary re-application of operations B, E, F, and I, the system more efficiently generates the new image.
Although the above-described scheme provides enhanced efficiency in updating images when operations change, as the number of operations that are performed on the same region of the image increases, the time it takes to re-apply those operations and update the image increases. The updating time is somewhat unpredictable to the user because it is affected by the number of operations that have to be re-applied, as well as by the relative complexity of those operations. For example, referring now to FIG. 2a, there is shown a background image 101 with four regions 201-204. A modification to operation 205 in region 201 is relatively slow to update, because there are many operations 209 in region 201 that must be re-applied. By contrast, a modification to operation 206 in region 202, or to operation 208 in region 204, would be relatively quick to update, because in each of these regions there are only two, relatively simple operations 210 and 206, or 212 and 208, to be re-applied. However, a modification to operation 207 in region 203 would be relatively slow to update because operation 211 is relatively complex and therefore takes longer to re-apply than does operations 209, 210, or 212. Since the user may not be aware of the number or complexity of underlying operations when making a change, there is unpredictability in the update time that will result from the change.
Furthermore, operations are not always stacked neatly on top of one another. For example, referring now to FIG. 2b, there is shown a background image 101 with three overlapping lens objects 213, 214, 215 containing operations. Because of the configuration of the lens objects, an update to an operation in lens object 215 may require updating of lens object 214, which in turn requires updating of lens object 213. Thus, nearly the entire background image 101 needs to be regenerated even when the change to one of the lens objects may be relatively small. This can lead to long recalculation delays as well as unpredictability in the update time.